package com.lzj.demo.design.chain.fzw.chain;

import com.lzj.demo.design.chain.fzw.AuthInfo;
import lombok.extern.slf4j.Slf4j;

import java.util.Date;

@Slf4j
public abstract class AuthLink {
    /**
     * 级别人员id
     * */
    protected String levelUserId;
    /**
     * 级别人员姓名
     * */
    protected String levelUserName;
    /**
     * 下一个审批节点
     * */
    private AuthLink nextAuth;

    public AuthLink(String levelUserId, String levelUserName) {
        this.levelUserId = levelUserId;
        this.levelUserName = levelUserName;
    }

    public AuthLink getNextAuth(){
        return nextAuth;
    }

    public AuthLink setNextAuth(AuthLink nextAuth){
        this.nextAuth = nextAuth;
        return this;
    }

    //审批
    public abstract AuthInfo doAuth(String uId, String orderId, Date authDate);
}
